package cn.wolfcode.wms.mapper;

import cn.wolfcode.wms.domain.SystemMenu;
import cn.wolfcode.wms.query.QueryForMenu;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface SystemMenuMapper {
    int deleteByPrimaryKey(Long id);

    int insert(SystemMenu record);

    SystemMenu selectByPrimaryKey(Long id);

    List<SystemMenu> selectAll();

    int updateByPrimaryKey(SystemMenu record);

    List<SystemMenu> selectQueryMenu(QueryForMenu qo);

    /**
     * 该方法主要用于删除父菜单的时候先删除子菜单
     * @param id
     */
    void deleteReltion(Long id);

    List<Map<String,Object>> selectgetMenuSn(String menuSn);

    List<Map<String,Object>> selectUserMenu(@Param("eId")Long eId, @Param("menuSn")String menuSn);
}